#include "window.h"
#include "glWidget.h"

Window::Window(unsigned int fps)
  : QWidget(0)
{
  mUI.setupUi(this);
  GLWidget* gl(new GLWidget(0, fps));
  connect(gl, SIGNAL(fps(uint)), this, SLOT(updateFPS(uint)));
  mUI.gridLayout->addWidget(gl, 0, 0, 1, 1);
}

void Window::updateFPS(unsigned int fps)
{
  mUI.fps->setText(QString::number(fps));
}
